/*  ----------------------------------------------------------------------------
 *  Arello Mobile
 *  Fast 3d Engine
 *  ----------------------------------------------------------------------------
 * Except where otherwise noted, this work is licensed under
 * http://creativecommons.org/licenses/by/3.0
 */

#ifndef RESOURCE_H
#define RESOURCE_H

namespace liba
{
namespace resource
{

class Resource
{
public:
	virtual ~Resource()
	{}
	virtual int read(void * data, int count)=0;
	virtual int skip(int count)=0;
	virtual bool is_valid()const=0;
	bool operator!()const
	{
		return !is_valid();
	}
	virtual int get_size()const=0;
	virtual int get_position()const=0;
	virtual void reset(int position = 0)=0;
};

} // namespace resource
} // namespace liba

using namespace liba;

#endif //RESOURCE_H

